package com.example.universitylibraryback.mapper;

import com.example.universitylibraryback.entity.BorrowRecord;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;

@Mapper
public interface BorrowRecordMapper {
    List<BorrowRecord> findAll();
    BorrowRecord findById(String recordId);
    List<BorrowRecord> findByReaderId(String readerId);
    List<BorrowRecord> findByBookId(String bookId);
    List<BorrowRecord> findOverdueRecords();
    int insert(BorrowRecord record);
    int update(BorrowRecord record);
    int updateReturnInfo(String recordId, String status, java.util.Date returnDate);
    int updateRenewCount(String recordId, int renewCount, java.util.Date dueDate);
}